home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / inet / internet-drafts / draft-ietf-tuba-clnp-04.txt < prev    next >
Text File  |  1993-07-30  |  50KB  |  1,519 lines

  1.  
  2. IETF                               Page 1
  3. July 2, 1993             CLNP for TUBA             Internet Draft
  4.  
  5.  
  6.               Use of ISO CLNP in TUBA Environments
  7.  
  8.  
  9.               David M. Piscitello
  10.                     Bellcore
  11.                   dave@sabre.bellcore.com
  12.  
  13.  
  14.                        Status of this Memo
  15.  
  16. This document is an Internet Draft.  Internet Drafts are working
  17. documents of the Internet Engineering Task Force (IETF), its
  18. Areas, and its Working Groups. Note that other groups may also
  19. distribute working documents as Internet Drafts.
  20.  
  21. Internet Drafts are draft documents valid for a maximum of six
  22. months. Internet Drafts may be updated, replaced, or obsoleted by
  23. other documents at any time.  It is not appropriate to use
  24. Internet Drafts as reference material or to cite them other than
  25. as a "working draft" or "work in progress."
  26.  
  27. Please check the Internet Draft abstract listing contained in the
  28. IETF Shadow Directories (cd internet-drafts) to learn the current
  29. status of this or any other Internet Draft.
  30.  
  31. This Internet-Draft specifies a profile of the ISO/IEC 8473
  32. Connectionless-mode Network Layer Protocol (CLNP, [1]) for use in
  33. conjunction with RFC 1347, TCP/UDP over Bigger Addresses (TUBA,
  34. [2]).  This draft document will be submitted to the RFC editor as
  35. a protocol specification. Distribution of this memo is unlimited.
  36. Please send comments to dave@eve.bellcore.com.
  37.  
  38.  
  39.                             Abstract
  40.  
  41. This document describes the use of CLNP to provide the lower-
  42. level service expected by Transmission Control Protocol (TCP,
  43. [3]) and User Datagram Protocol (UDP, [4]). CLNP provides
  44. essentially the same datagram service as Internet Protocol (IP,
  45. [5]), but offers a means of conveying bigger network addresses
  46. (with additional structure, to aid routing).
  47.  
  48. While the protocols offer nearly the same services, IP and CLNP
  49. are not identical. This document describes a means of preserving
  50. the semantics of IP information that is absent from CLNP while
  51. preserving consistency between the use of CLNP in Internet and
  52. OSI environments. This maximizes the use of already-deployed CLNP
  53. implementations.
  54.  
  55.  
  56.                          Acknowledgments
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68. IETF                               Page 2
  69. Internet Draft            CLNP for TUBA              July 2, 1993
  70.  
  71.  
  72. Many thanks to Ross Callon (Wellfleet Communications), John
  73. Curran (BBN), Cyndi Jung (3Com), Paul Brooks (UNSW), Brian
  74. Carpenter (CERN), Keith Sklower (Cal Berkeley), Dino Farinacci
  75. and Dave Katz (Cisco Systems) and David Oran (DEC) for their
  76. assistance in composing this text.
  77.  
  78.  
  79.                            Conventions
  80.  
  81. The following language conventions are used in the items of
  82. specification in this document:
  83.  
  84.    o+ Must, Shall, or Mandatory -- the item is an absolute
  85.      requirement of the specification.
  86.  
  87.    o+ Should or Recommended -- the item should generally be
  88.      followed for all but exceptional circumstances.
  89.  
  90.    o+ May or Optional -- the item is truly optional and may be
  91.      followed or ignored according to the needs of the
  92.      implementor.
  93.  
  94.  
  95. 1.  Terminology
  96.  
  97. To the extent possible, this document is written in the language
  98. of the Internet. For example, packet is used rather than
  99. "protocol data unit", and "fragment" is used rather than
  100. "segment".  There are some terms that carry over from OSI; these
  101. are, for the most part, used so that cross-reference between this
  102. document and RFC 994 [6] or ISO/IEC 8473 is not entirely painful.
  103. OSI acronyms are for the most part avoided.
  104.  
  105.  
  106. 2.  Introduction
  107.  
  108. The goal of this specification is to allow compatible and
  109. interoperable implementations to encapsulate TCP and UDP packets
  110. in CLNP data units. In a sense, it is more of a "hosts
  111. requirements" document for the network layer of TUBA
  112. implementations than a protocol specification. It is assumed that
  113. readers are familiar with RFC 791, RFC 792 [7], RFC 1122 [8],
  114. and, to a lesser extent, RFC 994 and ISO/IEC 8473.  This document
  115. is compatible with (although more restrictive than) ISO/IEC 8473;
  116. specifically, the order, semantics, and processing of CLNP header
  117. fields is consistent between this and ISO/IEC 8473.
  118.  
  119. [Editor's Note: RFC 994 contains the Draft International Standard
  120. version of ISO CLNP, in ASCII text. This is not the final version
  121. of the ISO/IEC protocol specification; however, it should provide
  122. sufficient background for the purpose of understanding the
  123. relationship of CLNP to IP, and the means whereby IP information
  124. is to be encoded in CLNP header fields. Postscript versions of
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134. IETF                               Page 3
  135. July 2, 1993             CLNP for TUBA             Internet Draft
  136.  
  137.  
  138. ISO CLNP and associated routing protocols are available via
  139. anonymous FTP from merit.edu, and may be found in the directory
  140. /pub/ISO/IEC.
  141.  
  142.  
  143. 3.  Overview of CLNP
  144.  
  145. ISO CLNP is a datagram network protocol. It provides
  146. fundamentally the same underlying service to a transport layer as
  147. IP. CLNP provides essentially the same maximum datagram size, and
  148. for those circumstances where datagrams may need to traverse a
  149. network whose maximum packet size is smaller than the size of the
  150. datagram, CLNP provides mechanisms for fragmentation (data unit
  151. identification, fragment/total length and offset). Like IP, a
  152. checksum computed on the CLNP header provides a verification that
  153. the information used in processing the CLNP datagram has been
  154. transmitted correctly, and a lifetime control mechanism ("Time to
  155. Live") imposes a limit on the amount of time a datagram is
  156. allowed to remain in the internet system. As is the case in IP, a
  157. set of options provides control functions needed or useful in
  158. some situations but unnecessary for the most common
  159. communications.
  160.  
  161. Table 1 provides a high-level comparison of CLNP to IP:
  162.  
  163.  
  164.  
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200. IETF                               Page 4
  201. Internet Draft            CLNP for TUBA              July 2, 1993
  202.  
  203.  
  204. Function                | ISO CLNP              | DOD IP
  205. ------------------------|-----------------------|-----------------------
  206. Header Length           | indicated in octets   | in 32-bit words
  207. Version Identifier      | 1 octet               | 4 bits
  208. Lifetime (Time to live) | 500 msec units        | 1 sec units
  209. Flags                   | Fragmentation allowed,| Don't Fragment,
  210.                         | More Fragments        | More Fragments,
  211.                         | Suppress Error Reports| <not defined>
  212. Packet Type             | 5 bits                | <not defined>
  213. Fragment Length         | 16 bits, in octets    | 16 bits, in octets
  214. Header Checksum         | 16-bit (Fletcher)     | 16-bit
  215. Total Length            | 16 bits, in octets    | <not defined>
  216. Addressing              | Variable length       | 32-bit fixed
  217. Data Unit Identifier    | 16 bits               | 16 bits
  218. Fragment offset         | 16 bits, in octets    | 13 bits, 8-octet units
  219. Higher Layer Protocol   | Selector in address   | PROTOcol (assigned #)
  220. Options                 | Security              | Security
  221.                         | Priority              | Precedence bits in TOS
  222.                         | Complete Source Route | Strict Source Route
  223.                         | Quality of Service    | Type of Service
  224.                         | Partial Source Route  | Loose Source Route
  225.                         | Record Route          | Record Route
  226.                         | Padding               | Padding
  227.                         | <defined herein>      | Timestamp
  228.  
  229.  
  230.  
  231.                 Table 1. Comparison of IP to CLNP
  232.  
  233. Note that the encoding of options differs between the two
  234. protocols, as do the means of higher level protocol
  235. identification. Note also that CLNP and IP differ in the way
  236. header and fragment lengths are represented, and that the
  237. granularity of lifetime control (time-to-live) is finer in CLNP.
  238. Some of these differences are not considered "issues", as CLNP
  239. provides flexibility in the way that certain options may be
  240. specified and encoded (this will facilitate the use and encoding
  241. of certain IP options without change in syntax); others, e.g.,
  242. higher level protocol identification and timestamp, must be
  243. accommodated in a transparent manner in this profile for correct
  244. operation of TCP and UDP, and continued interoperability with OSI
  245. implementations. Section 4 describes how header fields of CLNP
  246. must be populated to satisfy the needs of TCP and UDP.
  247.  
  248. Errors detected during the processing of a CLNP datagram may be
  249. reported using CLNP Error Reports. Implementations of CLNP for
  250. TUBA environments must be capable of processing Error Reports
  251. (this is consistent with the 1992 edition (2)  of the ISO/IEC
  252. 8473 standard).  Control messages (e.g., echo request/reply and
  253. redirect) are similarly handled in CLNP, i.e., identified as
  254. separate network layer packet types.  The relationship between
  255. CLNP Error and Control messages and Internet Control Message
  256. Protocol (ICMP, [7]), and issues relating to the handling of
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266. IETF                               Page 5
  267. July 2, 1993             CLNP for TUBA             Internet Draft
  268.  
  269.  
  270. these messages is described in Section 5.
  271.  
  272. The composition and processing of a TCP pseudo-header when CLNP
  273. is used to provide the lower-level service expected by TCP and
  274. UDP is described in Section 6.
  275.  
  276.  
  277.  
  278. 4.  Proposed Internet Header using CLNP
  279.  
  280. A summary of the contents of the CLNP header, as it is proposed
  281. for use in TUBA environments, is illustrated in Figure 4-1:
  282.  
  283.  
  284.     0                   1                   2                   3
  285.     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
  286.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  287.    |        ........Data Link Header........       | NLP ID        |
  288.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  289.    |Header Length  |     Version   | Lifetime (TTL)|Flags|  Type   |
  290.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  291.    |        Fragment Length        |           Checksum            |
  292.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  293.    | Dest Addr Len |               Destination Address...          |
  294.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  295.    |               ... Destination Address...                      |
  296.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  297.    |               ... Destination Address...                      |
  298.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  299.    |               ... Destination Address...                      |
  300.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  301.    |               ... Destination Address...                      |
  302.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  303.    | PROTO field   | Src  Addr Len |  Source  Address...           |
  304.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  305.    |               ... Source Address...                           |
  306.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  307.    |               ... Source Address...                           |
  308.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  309.    |               ... Source Address...                           |
  310.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  311.    |               ... Source Address...                           |
  312.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  313.    |       ... Source Address      |   Reserved    | Data Unit...  |
  314.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  315.    | ...Identifier |         Fragment Offset       |Total Length.. |
  316.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  317.    | ... of Packet |             Options...                        |
  318.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  319.    |                                                               |
  320.    :                                                               :
  321.    |                    Options  (see Table 1)                     |
  322.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332. IETF                               Page 6
  333. Internet Draft            CLNP for TUBA              July 2, 1993
  334.  
  335.  
  336.  
  337.           Note that each tick mark represents one bit position.
  338.  
  339.  
  340.  
  341.                         Figure 4-1. CLNP for TUBA
  342.  
  343. Note 1: For illustrative purposes, Figure 4-1 depicts Destination and
  344.         Source Addresses having a length of 19 octets, including the
  345.         PROTO/reserved field. In general, addresses can be variable
  346.         length, up to a maximum of 20 octets, including the
  347.         PROTO/reserved field.
  348.  
  349. Note 2: Due to differences in link layer protocols, it is not possible
  350.         to ensure that the packet starts on an even alignment.  Note,
  351.         however, that many link level protocols over which CLNP is operated
  352.         happen to use a odd length link (e.g., 802.2). (As profiled in
  353.         Figure 4-1, the rest of the CLNP packet is even-aligned.)
  354.  
  355.  
  356. The encoding of CLNP fields for use in TUBA environments is as
  357. follows.
  358.  
  359. 4.1  Network Layer Protocol Identification (NLP ID)
  360.  
  361. This one-octet field identifies this as the ISO/IEC 8473
  362. protocol; it must set to binary 1000 0001.
  363.  
  364. 4.2  Header Length Indication (Header Length)
  365.  
  366. Header Length is the length of the CLNP header in octets, and
  367. thus points to the beginning of the data. The value 255 is
  368. reserved. The header length is the same for all fragments of the
  369. same (original) CLNP packet.
  370.  
  371.  
  372.  
  373. 4.3  Version
  374.  
  375. This one-octet field identifies the version of the protocol; it
  376. must be set to a binary value 0000 0001.
  377.  
  378. 4.4  Lifetime (TTL)
  379.  
  380. Like the TTL field of IP, this field indicates the maximum time
  381. the datagram is allowed to remain in the internet system.  If
  382. this field contains the value zero, then the datagram must be
  383. destroyed; a host, however, must not send a datagram with a
  384. lifetime value of zero.  This field is modified in internet
  385. header processing.  The time is measured in units of 500
  386. milliseconds, but since every module that processes a datagram
  387. must decrease the TTL by at least one even if it process the
  388. datagram in less than 500 millisecond, the TTL must be thought of
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398. IETF                               Page 7
  399. July 2, 1993             CLNP for TUBA             Internet Draft
  400.  
  401.  
  402. only as an upper bound on the time a datagram may exist.  The
  403. intention is to cause undeliverable datagrams to be discarded,
  404. and to bound the maximum CLNP datagram lifetime. [Like IP, the
  405. colloquial usage of TTL in CLNP is as a coarse hop-count.]
  406.  
  407. 4.5  Flags
  408.  
  409. Three flags are defined. These occupy bits 0, 1, and 2 of the
  410. Flags/Type octet:
  411.  
  412.           0   1   2
  413.         +---+---+---+
  414.         | F | M | E |
  415.         | P | F | R |
  416.         +---+---+---+
  417.  
  418. The Fragmentation Permitted (FP) flag, when set to a value of one
  419. (1), is semantically equivalent to the "may fragment" value of
  420. the Don't Fragment field of IP; similarly, when set to zero (0),
  421. the Fragmentation Permitted flag is semantically equivalent to
  422. the "Don't Fragment" value of the Don't Fragment Flag of IP.
  423.  
  424. [Editor's Note: If the Fragmentation Permitted field is set to
  425. the value O, then the Data Unit Identifier, Fragment Offset, and
  426. Total Length fields are not present. This denotes a single
  427. fragment datagram. In such datagrams, the Fragment Length field
  428. contains the total length of the datagram.]
  429.  
  430. The More Fragments flag of CLNP is semantically and syntactically
  431. the same as the More Fragments flag of IP; a value of one (1)
  432. indicates that more segments/fragments are forthcoming; a value
  433. of zero (0) indicates that the last octet of the original packet
  434. is present in this segment.
  435.  
  436. The Error Report (ER) flag is used to suppress the generation of
  437. an error message by a host/router that detects an error during
  438. the processing of a CLNP datagram; a value of one (1) indicates
  439. that the host that originated this datagram thinks error reports
  440. are useful, and would dearly love to receive one if a host/router
  441. finds it necessary to discard its datagram(s).
  442.  
  443. 4.6  Type field
  444.  
  445. The type field distinguishes data CLNP packets from Error Reports
  446. from Echo packets. The following values of the type field apply:
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.  
  458.  
  459.  
  460.  
  461.  
  462.  
  463.  
  464. IETF                               Page 8
  465. Internet Draft            CLNP for TUBA              July 2, 1993
  466.  
  467.  
  468.   0   1   2   3   4   5   6   7
  469. +---+---+---+---+---+---+---+---+
  470. | flags     | 1 | 1 | 1 | 0 | 0 |  => Encoding of Type = data packet
  471. +---+---+---+---+---+---+---+---+
  472. | flags     | 0 | 0 | 0 | 0 | 1 |  => Encoding of Type = error report
  473. +---+---+---+---+---+---+---+---+
  474. | flags     | 1 | 1 | 1 | 1 | 0 |  => Encoding of Type = echo request
  475. +---+---+---+---+---+---+---+---+
  476. | flags     | 1 | 1 | 1 | 1 | 1 |  => Encoding of Type = echo reply
  477. +---+---+---+---+---+---+---+---+
  478.  
  479.  
  480.  
  481. Error Report packets are described in Section 5.
  482.  
  483. Echo packets and their use are described in RFC 1139 [9].
  484.  
  485.  
  486.  
  487. 4.7  Fragment Length
  488.  
  489. Like the Total Length of the IP header, the Fragment length field
  490. contains the length in octets of the fragment (i.e., this
  491. datagram) including both header and data.
  492.  
  493. [Note: CLNP also has a Total Length field, that contains the
  494. length of the original datagram; i.e., the sum of the length of
  495. the CLNP header plus the length of the data submitted by the
  496. higher level protocol, e.g., TCP or UDP. See Section 4.12.]
  497.  
  498. 4.8  Checksum
  499.  
  500. A checksum is computed on the header only. It is verified at each
  501. host/router that processes the packet; if header fields are
  502. changed during processing (e.g., the Lifetime), the checksum is
  503. modified. If the checksum is not used, this field must be coded
  504. with a value of zero (0). See Appendix A for algorithms used in
  505. the computation and adjustment of the checksum. Readers are
  506. encouraged to see [10] for a description of an efficient
  507. implementation of the checksum algorithm.
  508.  
  509. 4.9  Addressing
  510.  
  511. General purpose CLNP implementations must handle NSAPA addresses
  512. of variable length up to 20 octets, as defined in ISO/IEC 8348
  513. [11]. TUBA implementations, especially routers, must accommodate
  514. these as well. Thus, for compatibility and interoperability with
  515. OSI use of CLNP, the initial octet of the Destination Address is
  516. assumed to be an Authority and Format Indicator, as defined in
  517. ISO/IEC 8348. NSAP addresses may be between 8 and 20 octets long
  518. (inclusive).
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530. IETF                               Page 9
  531. July 2, 1993             CLNP for TUBA             Internet Draft
  532.  
  533.  
  534. TUBA implementations must support both ANSI and GOSIP style
  535. addresses; these are described in RFC 1237 [12], and illustrated
  536. in Figure 4-2.  RFC 1237 describes the ANSI/GOSIP initial domain
  537. parts as well as the format and composition of the domain
  538. specific part. It is further recommended that TUBA
  539. implementations support the assignment of system identifiers for
  540. TUBA/CLNP hosts defined in [13] for the purposes of host address
  541. autoconfiguration as described in [14]. Additional considerations
  542. specific to the interpretation and encoding of the selector part
  543. are described in sections 4.9.2 and 4.9.4.
  544.  
  545.                _______________
  546.                |<--__IDP_-->_|___________________________________
  547.                |AFI_|__IDI___|___________<--_DSP_-->____________|
  548.                |_47_|__0005__|DFI_|AA_|Rsvd_|_RD_|Area_|ID_|Sel_|
  549.         octets |_1__|___2____|_1__|_3_|__2__|_2__|_2___|_6_|_1__|
  550.  
  551.                     Figure 4-2 (a): GOSIP Version 2 NSAP structure.
  552.                ______________
  553.                |<--_IDP_-->_|_____________________________________
  554.                |AFI_|__IDI__|____________<--_DSP_-->_____________|
  555.                |_39_|__840__|DFI_|_ORG_|Rsvd_|RD_|Area_|_ID_|Sel_|
  556.         octets |_1__|___2___|_1__|__3__|_2___|_2_|__2__|_6__|_1__|
  557.  
  558.                      IDP   Initial Domain Part
  559.                      AFI   Authority and Format Identifier
  560.                      IDI   Initial Domain Identifier
  561.                      DSP   Domain Specific Part
  562.                      DFI   DSP Format Identifier
  563.                      ORG   Organization Name (numeric form)
  564.                      Rsvd  Reserved
  565.                      RD    Routing Domain Identifier
  566.                      Area  Area Identifier
  567.                      ID    System Identifier
  568.                      SEL   NSAP Selector
  569.  
  570.                  Figure 4-2 (b): ANSI NSAP address format for DCC=840
  571.  
  572. 4.9.1  _D_e_s_t_i_n_a_t_i_o_n__A_d_d_r_e_s_s__L_e_n_g_t_h__I_n_d_i_c_a_t_o_r
  573.  
  574. This field indicates the length, in octets, of the Destination
  575. Address.
  576.  
  577. 4.9.2  _D_e_s_t_i_n_a_t_i_o_n__A_d_d_r_e_s_s
  578.  
  579. This field contains an OSI NSAP address, as described in Section
  580. 4.9.
  581.  
  582. The final octet of the destination address must always contain
  583. the value of the PROTO field, as defined in IP.  The 8-bit PROTO
  584. field indicates the next level protocol used in the data portion
  585. of the CLNP datagram.  The values for various protocols are
  586. specified in "Assigned Numbers" [15]. For the PROTO field, the
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.  
  596. IETF                              Page 10
  597. Internet Draft            CLNP for TUBA              July 2, 1993
  598.  
  599.  
  600. value of zero (0) is reserved.
  601.  
  602. Tuba implementations that support TCP/UDP as well as OSI should
  603. use the protocol value (29) reserved for ISO transport protocol
  604. class 4.
  605.  
  606. 4.9.3  _S_o_u_r_c_e__A_d_d_r_e_s_s__L_e_n_g_t_h__I_n_d_i_c_a_t_o_r
  607.  
  608. This field indicates the length, in octets, of the Source
  609. Address.
  610.  
  611. 4.9.4  _S_o_u_r_c_e__A_d_d_r_e_s_s
  612.  
  613. This field contains an OSI NSAP address, as described in Section
  614. 4.9.
  615.  
  616. The final octet of the source address is reserved. It may be set
  617. to the protocol field value on transmission, and shall be ignored
  618. on reception (the value of zero must not be used).
  619.  
  620. 4.10  Data Unit Identifier
  621.  
  622. Like the Identification field of IP, this 16-bit field is used to
  623. distinguish segments of the same (original) packet for the
  624. purposes of reassembly.
  625.  
  626. 4.11  Fragment Offset
  627.  
  628. Like the Fragment Offset of IP, this 16-bit is used to identify
  629. the relative octet position of the data in this fragment with
  630. respect to the start of the data submitted to CLNP; i.e., it
  631. indicates where in the original datagram this fragment belongs.
  632.  
  633. 4.12  Total Length
  634.  
  635. The total length of the CLNP packet in octets is determined by
  636. the originator and placed in the Total Length field of the
  637. header. The Total Length field specifies the entire length of the
  638. original datagram, including both the header and data. This field
  639. must not be changed in any fragment of the original packet for
  640. the duration of the packet lifetime.
  641.  
  642. 4.13  Options
  643.  
  644. All CLNP options are "triplets" of the form <parameter code>,
  645. <parameter lenth>, and <parameter value>.  Both the parameter
  646. code and length fields are always one octet long; the length
  647. parameter value, in octets, is indicated in the parameter length
  648. field. The following options are defined for CLNP for TUBA.
  649.  
  650.  
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.  
  658.  
  659.  
  660.  
  661.  
  662. IETF                              Page 11
  663. July 2, 1993             CLNP for TUBA             Internet Draft
  664.  
  665.  
  666. 4.13.1  _S_e_c_u_r_i_t_y
  667.  
  668. The value of the parameter code field is binary 1100 0101. The
  669. length field must be set to the length of a Basic (and Extended)
  670. Security IP option(s) as identified in RFC1108 [16], plus 1.
  671. Octet 1 of the security parameter value field -- the CLNP
  672. Security Format Code -- is set to a binary value 0100 0000,
  673. indicating that the remaining octets of the security field
  674. contain either the Basic or Basic and Extended Security options
  675. as identified in RFC 1108. This encoding points to the
  676. administration of the source address (e.g., ISOC) as the
  677. administration of the security option; it is thus distinguished
  678. from the globally unique format whose definition is reserved for
  679. OSI use.  Implementations must examine the PROTO field in the
  680. source address; if the value of PROTO indicates the CLNP client
  681. is TCP or UDP, the security option described in RFC1108 is used.
  682.  
  683. The formats of the Security option, encoded as a CLNP option, is
  684. as follows. The CLNP option will be used to convey the Basic and
  685. Extended Security options as sub-options; i.e., the exact
  686. encoding of the Basic/Extended Security IP Option is carried in a
  687. single CLNP Security Option, with the length of the CLNP Security
  688. option reflecting the sum of the lengths of the Basic and
  689. Extended Security IP Option.
  690.  
  691.  
  692. +--------+--------+--------+--------+--------+------//-----+---
  693. |11000100|XXXXXXXX|01000000|10000010|YYYYYYYY|             |          ...
  694. +--------+--------+--------+--------+--------+------//-----+------
  695.  CLNP       CLNP     CLNP     BASIC   BASIC    BASIC
  696.  OPTION    OPTION   FORMAT  SECURITY  OPTION   OPTION
  697.  TYPE      LENGTH    CODE    TYPE     LENGTH   VALUE
  698.  (197)                       (130)
  699.  
  700.  
  701.       ---+------------+------------+----//-------+
  702.  ...     |  10000101  |  000LLLLL  |             |
  703.     -----+------------+------------+----//-------+
  704.             EXTENDED     EXTENDED    EXTENDED OPTION
  705.             OPTION       OPTION          VALUE
  706.            TYPE (133)    LENGTH
  707.  
  708.  
  709.  
  710. The syntax, semantics and  processing of the Basic and Extended
  711. IP Security Options are defined in RFC 1108.
  712.  
  713. 4.13.2  _T_y_p_e__o_f__S_e_r_v_i_c_e
  714.  
  715. The value of the parameter code field must be set to a value of
  716. binary 1100 0011 (the CLNP Quality of Service Option Code point).
  717. The length field must be set to the length of the type of service
  718. field as identified in RFC 1349, Type of Service in the Internet
  719.  
  720.  
  721.  
  722.  
  723.  
  724.  
  725.  
  726.  
  727.  
  728. IETF                              Page 12
  729. Internet Draft            CLNP for TUBA              July 2, 1993
  730.  
  731.  
  732. Protocol Suite [17], plus 1 (i.e., the value is 2). Octet 1 of
  733. the type of service parameter field is set to a binary value 0100
  734. 0000, indicating that the remaining octet of the Type Of Service
  735. field is to be encoded as described in RFC 1349.  This encoding
  736. points to the administration of the source address (e.g., ISOC)
  737. as the administration of the CLNP QOS option; it is thus
  738. distinguished from the globally unique QOS format whose
  739. definition is reserved for OSI use.  Implementations must examine
  740. the PROTO field in the source address; if the value of PROTO
  741. indicates the CLNP client is TCP or UDP, the TOS described in
  742. RFC1349 is used.
  743.  
  744.  
  745. +-----------+----------+----------+----------+
  746. | 1100 0011 | 00000010 | 01000000 | PPPTTTT0 |
  747. +-----------+----------+----------+----------+
  748.  CLNP QOS     OPTION    QOS FORMAT  IP TOS
  749.  TYPE (195)   LENGTH       CODE      OCTET
  750.  
  751.  
  752. The Type of Service octet consists of three fields:
  753.  
  754.  
  755.    0     1     2     3     4     5     6     7
  756. +-----+-----+-----+-----+-----+-----+-----+-----+
  757. |   PRECEDENCE    |          TOS          | MBZ |
  758. +-----+-----+-----+-----+-----+-----+-----+-----+
  759.  
  760. The first field, labeled "PRECEDENCE" above, is intended to
  761. denote the importance or priority of the datagram. The second
  762. field, labeled "TOS" above, denotes how the network should make
  763. tradeoffs between throughput, delay, reliability, and cost. The
  764. last field must be zero ("MBZ").
  765.  
  766. The processing of the type of service option is defined in
  767. RFC1349. The rules for applying TOS in Error and Report messages
  768. should correspond to those applied to the corresponding ICMP
  769. messages; i.e., error messages must always be sent with the
  770. default TOS; request messages may have any correct TOS value, and
  771. replies must be sent with the same value in the TOS field as was
  772. used in the corresponding request message.
  773.  
  774. [Editor's Note: It has been suggested that the IP precedence map
  775. directly into a CLNP option, Priority. The  feature will be
  776. provided irrespective of whether precedence is encoded in the TOS
  777. or Priority option.]
  778.  
  779. 4.13.3  _P_a_d_d_i_n_g
  780.  
  781. The padding field is used to lengthen the packet header to a
  782. convenient size. The parameter code field must be set to a value
  783. of binary 1100 1100. The value of the  parameter length field is
  784. variable. The parameter value may contain any value.
  785.  
  786.  
  787.  
  788.  
  789.  
  790.  
  791.  
  792.  
  793.  
  794. IETF                              Page 13
  795. July 2, 1993             CLNP for TUBA             Internet Draft
  796.  
  797.  
  798. +----------+----------+-----------+
  799. | 11001100 | LLLLLLLL | VVVV VVVV |
  800. +----------+----------+-----------+
  801.  
  802. 4.13.4  _S_o_u_r_c_e__R_o_u_t_i_n_g
  803.  
  804. Like the strict source route option of IP, the Complete Source
  805. Route option of CLNP is used to specify the exact and entire
  806. route an internet datagram must take. Similarly, the Partial
  807. Source Route option of CLNP provides the equivalent of the loose
  808. source route option of IP; i.e., a means for the source of an
  809. internet datagram to supply (some) routing information to be used
  810. by gateways in forwarding the internet datagram towards its
  811. destination.
  812.  
  813. The parameter code for Source Routing is binary 1100 1000. The
  814. length of the source routing parameter value is variable.
  815.  
  816. The first octet of the parameter value is a type code, indicating
  817. Complete Source Routing (binary 0000 0001) or partial source
  818. routing (binary 0000 0000). The second octet identifies the
  819. offset of the next network entity title to be processed in the
  820. list, relative to the start of the parameter (i.e., a value of 3
  821. is used to identify the first address in the list). The third
  822. octet begins the list of network entity titles.
  823.  
  824. 4.13.5  _R_e_c_o_r_d__R_o_u_t_e
  825.  
  826. Like the IP record route option, the Record route option of CLNP
  827. is used to trace the route a CLNP datagram takes.
  828.  
  829. The parameter code for Record Route is binary 1100 1011. The
  830. length of the record route parameter value is variable.
  831.  
  832. The first octet of the parameter value is a type code, indicating
  833. Complete Source Route (0000 0001) Partial Recording of Route
  834. (0000 0000). The second octet identifies the offset where the
  835. next network entity title may be recorded (i.e., the end of the
  836. current list), relative to the start of the parameter (i.e., a
  837. value of 3 is used to identify the initial recording position).
  838. If recording of route has been terminated (I'll be back...), this
  839. octet has a value 255. The third octet begins the list of network
  840. entity titles.
  841.  
  842. 4.13.6  _T_i_m_e_s_t_a_m_p
  843.  
  844. [Editor's Note: There is no timestamp option in edition 1 of
  845. ISO/IEC 8473, but the option has been proposed and submitted to
  846. ISO/IEC JTC1/SC6.]
  847.  
  848. The parameter code value 1110 1110 is used to identify the
  849. Timestamp option; the syntax and semantics of Timestamp are
  850. identical to that defined in IP.
  851.  
  852.  
  853.  
  854.  
  855.  
  856.  
  857.  
  858.  
  859.  
  860. IETF                              Page 14
  861. Internet Draft            CLNP for TUBA              July 2, 1993
  862.  
  863.  
  864. The Timestamp Option is defined in RFC 791. The CLNP parameter
  865. code 1110 1110 is used rather than the option type code 68 to
  866. identify the Timestamp option, and  the parameter value conveys
  867. the option length. Octet 1 of the Timestamp parameter value shall
  868. be encoded as the pointer (octet 3 of IP Timestamp); octet 2 of
  869. the parameter value shall be encoded as the overflow/format octet
  870. (octet 4 of IP Timestamp); the remaining octets shall be used to
  871. encode the timestamp list. The size is fixed by the source, and
  872. cannot be changed to accommodate additional timestamp
  873. information.
  874.  
  875.  
  876.         +--------+--------+--------+--------+
  877.         |11101110| length | pointer|oflw|flg|
  878.         +--------+--------+--------+--------+
  879.         |         network entity title      |
  880.         +--------+--------+--------+--------+
  881.         |             timestamp             |
  882.         +--------+--------+--------+--------+
  883.         |                 .                 |
  884.                           .
  885.  
  886.  
  887.  
  888. 5.  Error Reporting and Control Message Handling
  889.  
  890. CLNP and IP  differ in the way in which errors are reported to
  891. hosts. In IP environments, the Internet Control Message Protocol
  892. (ICMP, [7]) is used to return (error) messages to hosts that
  893. originate packets that cannot be processed. ICMP messages are
  894. transmitted as user data in IP datagrams. Unreachable
  895. destinations, incorrectly composed IP datagram headers, IP
  896. datagram discards due to congestion, and lifetime/reassembly time
  897. exceeded are reported; the complete internet header that caused
  898. the error plus 8 octets of the segment contained in that IP
  899. datagram are returned to the sender as part of the ICMP error
  900. message. For certain errors, e.g., incorrectly composed IP
  901. datagram headers, the specific octet which caused the problem is
  902. identified.
  903.  
  904. In CLNP environments, an unique message type, the Error Report
  905. type, is used in the network layer protocol header to distinguish
  906. Error Reports from CLNP datagrams. CLNP Error Reports are
  907. generated on detection of the same types of errors as with ICMP.
  908. Like ICMP error messages, the complete CLNP header that caused
  909. the error is returned to the sender in the data portion of the
  910. Error Report. Implementations should return at least 8 octets of
  911. the datagram contained in the CLNP datagram to the sender of the
  912. original CLNP datagram. Here too, for certain errors, the
  913. specific octet which caused the problem is identified
  914.  
  915. A summary of the contents of the CLNP Error Report, as it is
  916. proposed for use in TUBA environments, is illustrated in Figure
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.  
  926. IETF                              Page 15
  927. July 2, 1993             CLNP for TUBA             Internet Draft
  928.  
  929.  
  930. 5-1:
  931.  
  932.  
  933.     0                   1                   2                   3
  934.     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
  935.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  936.    |        ........Data Link Header........       | NLP ID        |
  937.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  938.    |Header Length  |     Version   | Lifetime (TTL)| 000 | Type=ER |
  939.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  940.    |  TOTAL Length of Error Report |           Checksum            |
  941.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  942.    | Dest Addr Len |               Destination Address...          |
  943.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  944.    |               ... Destination Address...                      |
  945.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  946.    |               ... Destination Address...                      |
  947.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  948.    |               ... Destination Address...                      |
  949.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  950.    |               ... Destination Address...                      |
  951.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  952.    | PROTO field   | Src  Addr Len |  Source  Address...           |
  953.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  954.    |               ... Source Address...                           |
  955.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  956.    |               ... Source Address...                           |
  957.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  958.    |               ... Source Address...                           |
  959.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  960.    |               ... Source Address...                           |
  961.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  962.    |       ... Source Address      | Reason for Discard (type/len) |
  963.    |                               |   1100 0001   | 0000 0010     |
  964.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  965.    |     Reason for Discard        |    Options...                 |
  966.    |   code        |   pointer     |                               |
  967.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  968.    |                           Options                             |
  969.    :                                                               :
  970.    |                                                               |
  971.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  972.  
  973.           Note that each tick mark represents one bit position.
  974.  
  975.  
  976.                         Figure 5-1. Error Report Format
  977.  
  978.  
  979.  
  980.  
  981.  
  982.  
  983.  
  984.  
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.  
  992. IETF                              Page 16
  993. Internet Draft            CLNP for TUBA              July 2, 1993
  994.  
  995.  
  996. 5.1  Rules for processing an Error Report
  997.  
  998. The following is a summary of the rules for processing an Error
  999. Report:
  1000.  
  1001.    o+ An Error Report is not generated to report a problem
  1002.      encountered while processing an Error Report.
  1003.  
  1004.    o+ Error Reports may not be fragmented (hence, the
  1005.      fragmentation part is absent).
  1006.  
  1007.    o+ The Reason for Discard Code field is populated with one of
  1008.      the values from Table 5-1.
  1009.  
  1010.    o+ The Pointer field is populated with number of the first
  1011.      octet of the field that caused the Error Report to be
  1012.      generated. If it is not possible to identify the offending
  1013.      octet, this field must be zeroed.
  1014.  
  1015.    o+ If the Priority or Type of Service option is present in the
  1016.      errored datagram, the Error Report shall specify the same
  1017.      option, using the value specified in the original datagram.
  1018.  
  1019.    o+ If the Security option is present in the errored datagram,
  1020.      the Error Report shall specify the same option, using the
  1021.      value specified in the original datagram; if the Security
  1022.      option is not supported, no Error Report is to be generated
  1023.      (i.e., "silently discard" the received datagram).
  1024.  
  1025.    o+ If the Complete Source Route option is specified in the
  1026.      errored datagram, the Error Report must compose a reverse of
  1027.      that route, and return the datagram along the same path.
  1028.  
  1029. 5.2  Comparison of ICMP and CLNP Error Messages
  1030.  
  1031. Table 5-1 provides a loose comparison of ICMP message types and
  1032. codes to CLNP Error Type Codes (values in Internet ASCII):
  1033.  
  1034.  
  1035.  
  1036.  
  1037.  
  1038.  
  1039.  
  1040.  
  1041.  
  1042.  
  1043.  
  1044.  
  1045.  
  1046.  
  1047.  
  1048.  
  1049.  
  1050.  
  1051.  
  1052.  
  1053.  
  1054.  
  1055.  
  1056.  
  1057.  
  1058. IETF                              Page 17
  1059. July 2, 1993             CLNP for TUBA             Internet Draft
  1060.  
  1061.  
  1062. CLNP Error Type  Codes            | ICMP Message           (Type, Code)
  1063. ----------------------------------|------------------------------------
  1064. Reason not specified          (0) | Parameter Problem           (12, 0)
  1065. Protocol Procedure Error      (1) | Parameter Problem           (12, 0)
  1066. Incorrect Checksum            (2) | Parameter Problem           (12, 0)
  1067. PDU Discarded--Congestion     (3) | Source Quench                (4, 0)
  1068. Header Syntax Error           (4) | Parameter problem           (12, 0)
  1069. Need to Fragment could not    (5) | Frag needed, DF set          (3, 4)
  1070. Incomplete PDU received       (6) | Parameter Problem           (12, 0)
  1071. Duplicate Option              (7) | Parameter Problem           (12, 0)
  1072. Destination Unreachable     (128) | Dest Unreachable,Net unknown (3, 0)
  1073. Destination Unknown         (129) | Dest Unreachable,host unknown(3, 1)
  1074. Source Routing Error        (144) | Source Route failed          (3, 5)
  1075. Source Route Syntax Error   (145) | Source Route failed          (3, 5)
  1076. Unknown Address in Src Route(146) | Source Route failed          (3, 5)
  1077. Path not acceptable         (147) | Source Route failed          (3, 5)
  1078. Lifetime expired            (160) | TTL exceeded                (11, 0)
  1079. Reassembly Lifetime Expired (161) | Reassembly time exceeded    (11, 1)
  1080. Unsupported Option          (176) | Parameter Problem           (12, 0)
  1081. Unsupported Protocol Version(177) | Parameter problem           (12, 0)
  1082. Unsupported Security Option (178) | Parameter problem           (12, 0)
  1083. Unsupported Src Rte Option  (179) | Parameter problem           (12, 0)
  1084. Unsupported Rcrd Rte        (180) | Parameter problem           (12, 0)
  1085. Reassembly interference     (192) | Reassembly time exceeded    (11,1)
  1086.  
  1087.  
  1088. Table 5-1. Comparison of CLNP Error Reports to ICMP Error Messages
  1089.  
  1090. Note 1: The current use of the source quench is only
  1091.         when packets are discarded, and thus the current use
  1092.         meaning is the same; if a future RFC describes a more
  1093.         robust treatment of the source quench, the applicability
  1094.         of this CLNP Error Report Type should be reconsidered.
  1095.  
  1096. Note 2: There are no corresponding CLNP Error Report Codes for the
  1097.         following ICMP error message types:
  1098.         - Protocol Unreachable  (3, 2)
  1099.         - Port Unreachable      (3, 3)
  1100.         [ED. There are error code points available in the ER type
  1101.              code block that can be used to identify these message types.]
  1102.  
  1103.  
  1104.  
  1105. 6.  Pseudo-Header Considerations
  1106.  
  1107. A checksum is computed on UDP and TCP segments to verify the
  1108. integrity of the UDP/TCP segment. To further verify that the
  1109. UDP/TCP segment has arrived at its correct destination, a
  1110. pseudo-header consisting of information used in the delivery of
  1111. the UDP/TCP segment is composed and included in the checksum
  1112. computation.
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124. IETF                              Page 18
  1125. Internet Draft            CLNP for TUBA              July 2, 1993
  1126.  
  1127.  
  1128. To compute the checksum on a UDP or TCP segment prior to
  1129. transmission, implementations must compose a pseudo-header to the
  1130. UDP/TCP segment consisting of the following information that will
  1131. be used when composing the CLNP datagram:
  1132.  
  1133.    o+ Destination Address Length Indicator
  1134.  
  1135.    o+ Destination Address (including PROTO field)
  1136.  
  1137.    o+ Source Address Length Indicator
  1138.  
  1139.    o+ Source Address (including Reserved field)
  1140.  
  1141.    o+ A two-octet encoding of the Protocol value
  1142.  
  1143.    o+ TCP/UDP segment length
  1144.  
  1145. Figure 5-1 illustrates the resulting pseudo-header when both
  1146. source and destination addresses are maximum length.
  1147.  
  1148.  
  1149.     0                   1                   2                   3
  1150.     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
  1151.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1152.    | Dest Addr Len |               Destination Address...          |
  1153.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1154.    |               ... Destination Address...                      |
  1155.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1156.    |               ... Destination Address...                      |
  1157.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1158.    |               ... Destination Address...                      |
  1159.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1160.    |               ... Destination Address...                      |
  1161.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1162.    |    (PROTO)    | Src  Addr Len |  Source  Address...           |
  1163.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1164.    |               ... Source Address...                           |
  1165.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1166.    |               ... Source Address...                           |
  1167.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1168.    |               ... Source Address...                           |
  1169.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1170.    |               ... Source Address...                           |
  1171.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1172.    | ...           | (Reserved)    |    Protocol                   |
  1173.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1174.    |   UDP/TCP segment length      |
  1175.    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  1176.  
  1177. Figure 5-1. Pseudo-header
  1178.  
  1179. If the length of the {source address length indicator + source
  1180. address + destination address indicator + destination address }
  1181.  
  1182.  
  1183.  
  1184.  
  1185.  
  1186.  
  1187.  
  1188.  
  1189.  
  1190. IETF                              Page 19
  1191. July 2, 1993             CLNP for TUBA             Internet Draft
  1192.  
  1193.  
  1194. is not an integral number of octets, a trailing 0x0 nibble is
  1195. padded. If GOSIP compliant NSAP addresses are used, this never
  1196. happens (this is known as the Farinacci uncertainty principle).
  1197. The last byte in the Destination Address has the value 0x06 for
  1198. TCP and 0x11 for UDP, and that the Protocol field is encoded
  1199. 0x0006 for TCP and 0x0011 for UDP If needed, an octet of zero is
  1200. added to the end of the UDP/TCP segment to pad the datagram to a
  1201. length that is a multiple of 16 bits. In all other respects,
  1202. rules for computing the checksum are consistent with RFC 793 and
  1203. RFC 768.
  1204.  
  1205.  
  1206.  
  1207.  
  1208.  
  1209.  
  1210.  
  1211.  
  1212.  
  1213.  
  1214.  
  1215.  
  1216.  
  1217.  
  1218.  
  1219.  
  1220.  
  1221.  
  1222.  
  1223.  
  1224.  
  1225.  
  1226.  
  1227.  
  1228.  
  1229.  
  1230.  
  1231.  
  1232.  
  1233.  
  1234.  
  1235.  
  1236.  
  1237.  
  1238.  
  1239.  
  1240.  
  1241.  
  1242.  
  1243.  
  1244.  
  1245.  
  1246.  
  1247.  
  1248.  
  1249.  
  1250.  
  1251.  
  1252.  
  1253.  
  1254.  
  1255.  
  1256. IETF                              Page 20
  1257. Internet Draft            CLNP for TUBA              July 2, 1993
  1258.  
  1259.  
  1260. 7.  REFERENCES
  1261.  
  1262. [1]     ISO/IEC 8473-1992. International Standards Organization -- Data
  1263.         Communications -- Protocol for Providing the Connectionless-mode
  1264.         Network Service, Edition 2.
  1265.  
  1266. [2]     Callon, R., TCP/UDP over Bigger Addresses (TUBA), Request for
  1267.         Comments 1347, Network Information Center, SRI
  1268.         International, Menlo Park, CA, May 1992.
  1269.  
  1270. [3]     Postel, J., Transmission Control Protocol (TCP). Request for
  1271.         Comments 793, Network Information Center, SRI
  1272.         International, Menlo Park, CA, 1981 September.
  1273.  
  1274. [4]     Postel, J., User Datagram Protocol (UDP). Request for Comments 768,
  1275.         Network Information Center, SRI International, Menlo Park, CA.
  1276.  
  1277. [5]     Postel, J., Internet Protocol (IP). Request for Comments 791,
  1278.         Network Information Center, SRI International, Menlo Park,
  1279.         CA, 1981 September.
  1280.  
  1281. [6]     Chapin, L., ISO DIS 8473, Protocol for Providing the
  1282.         Connectionless Network Service. Request for Comments 994,
  1283.         Network Information Center, SRI International, Menlo Park, CA,
  1284.         1986 March.
  1285.  
  1286. [7]     Postel, J.  Internet Control Message Protocol. Request for
  1287.         Comments 792, Network Information Center, SRI International,
  1288.         Menlo Park, CA  1981 September.
  1289.  
  1290. [8]     Braden, R.,ed.  Requirements for Internet hosts - communication layers
  1291.         Request for Comments 1122. Network Information Center, SRI
  1292.         International, Menlo Park, CA, 1989 October.
  1293.  
  1294. [9]     Hagens, R. and C. Wittbrodt, CLNP Ping, Request for Comments
  1295.         1139, Network Information Center, SRI International, Menlo
  1296.         Park, CA. 1993 May.
  1297.  
  1298. [10]    Sklower, K., <checksum implemenation article from CCR>
  1299.  
  1300. [11]    ISO/IEC 8348-1992. International Standards Organization--Data
  1301.         Communications--OSI Network Layer Service and Addressing.
  1302.  
  1303. [12]    Callon, R.,  NSAPA Guidelines for the Internet,
  1304.         Request for Comments RFC 1237, Network Information Center, SRI
  1305.         International, Menlo Park, CA.
  1306.  
  1307. [13]    Piscitello, D., Assignment of System Identifiers for TUBA/CLNP
  1308.         hosts, Internet-drafts (draft-tuba-sysids-01.txt).
  1309.  
  1310. [14]    ISO/IEC 9542:1988/PDAM 1. Information Processing Systems -- Data
  1311.         Communications -- End System to Intermediate System Routeing
  1312.         Exchange Protocol for use in conjunction with the protocol for
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322. IETF                              Page 21
  1323. July 2, 1993             CLNP for TUBA             Internet Draft
  1324.  
  1325.  
  1326.         providing the connectionless-mode network service -- Amendment 1:
  1327.         Dynamic Discovery of OSI NSAP Addresses by End Systems.
  1328.  
  1329. [15]    Reynolds, J., and J. Postel, Assigned Numbers.
  1330.         Request for Comments 1340, Network Information Center, SRI
  1331.         International, Menlo Park, CA. 1992 July.
  1332.  
  1333. [16]    Kent, S., Security Option for IP,
  1334.         Request for Comments 1108, Network Information Center, SRI
  1335.         International, Menlo Park, CA.
  1336.  
  1337. [17]    Almquist, P., Type of Service in the Internet
  1338.         Protocol Suite. Request for Comments 1349, Network Information
  1339.         Center, SRI International, Menlo Park, CA.
  1340.  
  1341.  
  1342.  
  1343.  
  1344.  
  1345.  
  1346.  
  1347.  
  1348.  
  1349.  
  1350.  
  1351.  
  1352.  
  1353.  
  1354.  
  1355.  
  1356.  
  1357.  
  1358.  
  1359.  
  1360.  
  1361.  
  1362.  
  1363.  
  1364.  
  1365.  
  1366.  
  1367.  
  1368.  
  1369.  
  1370.  
  1371.  
  1372.  
  1373.  
  1374.  
  1375.  
  1376.  
  1377.  
  1378.  
  1379.  
  1380.  
  1381.  
  1382.  
  1383.  
  1384.  
  1385.  
  1386.  
  1387.  
  1388. IETF                              Page 22
  1389. Internet Draft            CLNP for TUBA              July 2, 1993
  1390.  
  1391.  
  1392. Appendix A. Checksum Algorithms (from ISO/IEC 8473)
  1393.  
  1394.  
  1395.  
  1396. Symbols used in algorithms:
  1397.         c0, c1          variables used in the algorithms
  1398.         i               position of octet in header (first
  1399.                         octet is i=1)
  1400.         Bi              value of octet i in the header
  1401.         n               position of first octet of checksum (n=8)
  1402.         L               Length of header in octets
  1403.         X               Value of octet one of the checksum parameter
  1404.         Y               Value of octet two of the checksum parameter
  1405.  
  1406. Addition is performed in one of the two following modes:
  1407.  
  1408.    o+ modulo 255 arithmetic;
  1409.  
  1410.    o+ eight-bit one's complement arithmetic;
  1411.  
  1412. The algorithm for Generating the Checksum Parameter Value is as
  1413. follows:
  1414.  
  1415.   A.  Construct the complete header with the value of the
  1416.       checksum parameter field set to zero; i.e., c0 <- c1 <- 0;
  1417.  
  1418.   B.  Process each octet of the header sequentially from i=1 to L
  1419.       by:
  1420.  
  1421.          o+ c0 <- c0 + Bi
  1422.  
  1423.          o+ c1 <- c1 + c0
  1424.  
  1425.   C.  Calculate X, Y as follows:
  1426.  
  1427.          o+ X <- (L - 8)(c0 - c1) modulo 255
  1428.  
  1429.          o+ Y <- (L - 7)(-C0) + c1
  1430.  
  1431.   D.  If X = 0, then X <- 255
  1432.  
  1433.   E.  If Y = 0, then Y <- 255
  1434.  
  1435.   F.  place the values of X and Y in octets 8 and 9 of the
  1436.       header, respectively
  1437.  
  1438. The algorithm for checking the value of the checksum parameter is
  1439. as follows:
  1440.  
  1441.   A.  If octets 8 and 9 of the header both contain zero, then the
  1442.       checksum calculation has succeeded; else if either but not
  1443.       both of these octets contains the value zero then the
  1444.       checksum is incorrect; otherwise, initialize: c0 <- c1 <- 0
  1445.  
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454. IETF                              Page 23
  1455. July 2, 1993             CLNP for TUBA             Internet Draft
  1456.  
  1457.  
  1458.   B.  Process each octet of the header sequentially from i = 1 to
  1459.       L by:
  1460.  
  1461.          o+ c0 <- c0 + Bi
  1462.  
  1463.          o+ c1 <- c1 + c0
  1464.  
  1465.   C.  When all the octets have been processed, if c0 = c1 = 0,
  1466.       then the checksum calculation has succeeded, else it has
  1467.       failed.
  1468.  
  1469. There is a separate algorithm to adjust the checksum parameter
  1470. value when a octet has been modified (such as the TTL). Suppose
  1471. the value in octet k is changed by Z = newvalue - oldvalue. If X
  1472. and Y denote the checksum values held in octets n and n+1
  1473. respectively, then adjust X and Y as follows:
  1474.  
  1475. If X = 0 and Y = 0 then do nothing, else if X = 0 or Y = 0 then
  1476. the checksum is incorrect, else:
  1477.  
  1478. X <- (k - n - 1)Z + X   modulo 255
  1479.  
  1480. Y <- (n - k)Z + Y       modulo 255
  1481.  
  1482. If X = 0, then X <- 255; if Y = 0, then Y <- 255.
  1483.  
  1484. In the example, n = 89; if the octet altered is the TTL (octet
  1485. 4), then k = 4. For the case where the lifetime is decreased by
  1486. one unit (Z = -1), the assignment statements for the new values
  1487. of X and Y in the immediately preceeding algorithm simplify to:
  1488.  
  1489. X <- X + 5      Modulo 255
  1490.  
  1491. Y <- Y - 4      Modulo 255
  1492.  
  1493.  
  1494.  
  1495.  
  1496.  
  1497.  
  1498.  
  1499.  
  1500.  
  1501.  
  1502.  
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.  
  1516.  
  1517.  
  1518.  
  1519.